package com.ruoyi.system.domain;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 原料分类管理对象 material_category
 *
 * @author ruoyi
 * @date 2025-05-26
 */
public class MaterialCategory extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 分类唯一标识符(主键) */
    private Long id;

    /** 分类名称(如"粮食类") */
    @Excel(name = "分类名称")
    private String categoryName;

    /** 分类编码(如"LS-001") */
    @Excel(name = "分类编码")
    private String categoryCode;

    /** 该分类下原料数量(动态计算) */
    @Excel(name = "该分类下原料数量(动态计算)")
    private Long materialCount;

    /** 分类排序序号(用于前端展示顺序) */
    @Excel(name = "分类排序序号(用于前端展示顺序)")
    private Long sortOrder;

    /** 分类状态 */
    @Excel(name = "分类状态")
    private String status;

    /** 自定义显示顺序(覆盖sort_order) */
    @Excel(name = "自定义显示顺序(覆盖sort_order)")
    private Long displayOrder;

    /** 父分类ID(支持多级分类) */
    @Excel(name = "父分类ID(支持多级分类)")
    private Long parentId;

    /** 分类层级(1=一级分类,2=二级分类...) */
    @Excel(name = "分类层级(1=一级分类,2=二级分类...)")
    private Integer level;

    /** 分类路径(如"1,5,8"表示1→5→8) */
    @Excel(name = "分类路径")
    private String path;

    /** 手机号 */
    @Excel(name = "手机号")
    private String phone;

    public void setId(Long id)
    {
        this.id = id;
    }

    public Long getId()
    {
        return id;
    }

    public void setCategoryName(String categoryName)
    {
        this.categoryName = categoryName;
    }

    public String getCategoryName()
    {
        return categoryName;
    }

    public void setCategoryCode(String categoryCode)
    {
        this.categoryCode = categoryCode;
    }

    public String getCategoryCode()
    {
        return categoryCode;
    }

    public void setMaterialCount(Long materialCount)
    {
        this.materialCount = materialCount;
    }

    public Long getMaterialCount()
    {
        return materialCount;
    }

    public void setSortOrder(Long sortOrder)
    {
        this.sortOrder = sortOrder;
    }

    public Long getSortOrder()
    {
        return sortOrder;
    }

    public void setStatus(String status)
    {
        this.status = status;
    }

    public String getStatus()
    {
        return status;
    }

    public void setDisplayOrder(Long displayOrder)
    {
        this.displayOrder = displayOrder;
    }

    public Long getDisplayOrder()
    {
        return displayOrder;
    }

    public void setParentId(Long parentId)
    {
        this.parentId = parentId;
    }

    public Long getParentId()
    {
        return parentId;
    }

    public void setLevel(Integer level)
    {
        this.level = level;
    }

    public Integer getLevel()
    {
        return level;
    }

    public void setPath(String path)
    {
        this.path = path;
    }

    public String getPath()
    {
        return path;
    }

    public void setPhone(String phone)
    {
        this.phone = phone;
    }

    public String getPhone()
    {
        return phone;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("categoryName", getCategoryName())
                .append("categoryCode", getCategoryCode())
                .append("materialCount", getMaterialCount())
                .append("sortOrder", getSortOrder())
                .append("status", getStatus())
                .append("displayOrder", getDisplayOrder())
                .append("parentId", getParentId())
                .append("level", getLevel())
                .append("path", getPath())
                .append("remark", getRemark())
                .append("createTime", getCreateTime())
                .append("updateTime", getUpdateTime())
                .append("phone", getPhone())
                .toString();
    }
}
